package com.example.g5project.chat.model.param;

import com.example.g5project.chat.model.common.AccountParam;
import com.example.g5project.chat.model.enumeration.IdentityEnum;
import com.example.g5project.chat.model.enumeration.MessageTypeEnum;
import io.swagger.annotations.ApiModelProperty;
import javax.validation.constraints.Max;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@Builder
@AllArgsConstructor
@NoArgsConstructor
public class MessageReceiveParam {

    @ApiModelProperty("所属会话id")
    @NotNull(message = "所属会话id不可为空")
    @Min(value = 1, message = "所属会话id最小为1")
    private Integer chatId;

    @ApiModelProperty("发送者")
    private AccountParam send;

    @ApiModelProperty("接收者")
    private AccountParam receive;

    @ApiModelProperty("查询数量")
    private Integer count;

    @ApiModelProperty("开始时间时间戳，秒")
    @NotNull(message = "开始时间时间戳不可为空")
    private Integer startTime;

    @ApiModelProperty("结束时间时间戳，秒")
    @NotNull(message = "结束时间时间戳不可为空")
    private Integer endTime;

    @ApiModelProperty("最后一条消息的msgKey，没有的话传null")
    private String lastMsgKey;

}
